package yixaun.tim.common;

import com.google.gson.annotations.SerializedName;
import lombok.Data;

import java.io.Serializable;

/**
 * @author Element
 * @Package com.sevlow.sdk.tim.common.error
 * @date 2019-05-27 11:45
 * @Description: TODO
 */
@Data
public class TimException extends RuntimeException implements Serializable {

	private static final long serialVersionUID = 3469414966034151505L;

	@SerializedName("ErrorCode")
	private int errorCode;

	@SerializedName("ErrorInfo")
	private String errorInfo;


	public TimException(Integer errorCode , String errorInfo){
		this.errorCode = errorCode ;
		this.errorInfo = errorInfo ;
	}

	public TimException(String errorInfo){
		this.errorCode = 0 ;
		this.errorInfo = errorInfo ;
	}


}
